<div class="r0 p20 pt10 col-xs-12" ng-controller="userModuleListCtrl">
<div class="col-xs-6 f16 fb p0 mb5">模块列表：{{$stateParams.projectName}}</div>
<div class="col-xs-6 f14 p0 mb5 tr">
	<a type="button" class="btn btn-primary btn-sm" id="refresh" ng-click="getData(list.page.currentPage)"> <i class="iconfont fb">&#xe611;&nbsp;</i>刷新</a>
	<a type="button" class="btn btn-purple btn-sm" onclick="history.back(-1);"> <i class="iconfont fb">&#xe605;&nbsp;</i>后退</a>
</div>

<div class="col-xs-12 mt20 p0 mb10 f14 tr">
	<a type="button" class="btn btn-success btn-sm cursor"
		ng-click="detail('新增模块',700,'user/module/detail.do?id=NULL&projectId='+$stateParams.projectId)"> 
		<i class="iconfont fb">&#xe604;</i>&nbsp;
		<span>新增模块</span>
	</a>
</div>

<div class="col-xs-3 f16 fb pl0 mb10 pb5 mt20">
	<span>模块列表</span>
</div>
<div class="col-xs-12 p0">
	<table class="table table-bordered table-hover">
		<thead>
			<tr class="BGEEE">
				<th class="tc">名称</th>
				<th class="tc">Url前缀</th>
				<td class="tc">排序</td>
				<th class="tc">操作</th>
			</tr>
		</thead>
		<tbody>
			<tr ng-repeat="item in list">
				<td class="tc w200">{{item.name}}</td>
				<td class="tc w200">{{item.url}}</td>
				<td class="tc w50">{{item.sequence}}</td>
				<td class="tc">
				
				<a class="f12 text-primary mr10 cursor" ng-href="#/user/interface/list/{{item.projectId}}/{{item.id}}/{{item.name}}"> 
					<i class="iconfont f12">&#xe614; 接口</i>
				</a>
				
				<a class="f12 text-primary mr10 cursor" ng-href="#/user/article/list/{{item.projectId}}/{{item.id}}/ARTICLE"> 
					<i class="iconfont f12">&#xe637; 文章</i>
				</a>
				
				<a class="f12 text-primary mr10 cursor" ng-href="#/user/source/list/{{item.projectId}}/{{item.id}}"> 
					<i class="iconfont f12">&#xe638; 资源</i>
				</a>
				
				<a class="f12 text-primary mr10 cursor" ng-href="#/user/article/list/{{item.projectId}}/{{item.id}}/DICTIONARY"> 
					<i class="iconfont f12">&#xe61c;数据字典</i>
				</a>
				<a class="f12 text-primary mr10 cursor" ng-href="front/interface/download/pdf.do?moduleId={{item.id}}"> 
					<i class="iconfont f12">&#xe61e; 下载接口</i>
				</a>
				<a class="f12 text-primary mr10 cursor" ng-if="showOperation('PROJECT',item.projectId)"
					ng-click="detail('编辑【'+item.name+'】',700,'user/module/detail.do?id='+item.id)"> 
					<i class="iconfont f12">&#xe618;修改</i>
				</a>
			
				<a class="f12 text-danger mr10 cursor" title="删除" ng-if="showOperation('PROJECT',item.projectId)"
					ng-click="del('user/module/delete.do?id='+item.id,item.name)">
					<i class="iconfont f12">&#xe60e;删除</i>
				</a>
				
				<div class="w50 fr tl" ng-if="showOperation('PROJECT',item.projectId)">
					<a class="f12 text-danger mr10 cursor" title="向上移" ng-click="changeSequence('user/module/changeSequence.do',item.id,list[$index-1].id)" ng-if="$index>0">
						<i class="iconfont f12">&#xe623;</i>
					</a>
					<a class="f12 text-danger mr10 cursor" title="向下移" ng-click="changeSequence('user/module/changeSequence.do',item.id,list[$index+1].id)" ng-if="$index<list.length-1">
						<i class="iconfont f12">&#xe624;</i>
					</a>
				</div>
				</td>
			</tr>
		</tbody>
	</table>
	<div ui-view="page"></div>
</div>
</div>
<div class="cb"></div>

